package com.gxc.controller;

import com.gxc.config.ConfigBeanProperties;
import javax.annotation.Resource;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 测试.
 * @author 宫新程
 * @since 2018/12/3 11:03 AM
 */
@RestController
public class PropertiesController {

  @Resource private ConfigBeanProperties configBeanProperties;

  /** 测试获取properties中的key:value. */
  @RequestMapping("/properties")
  public String test() {
    return configBeanProperties.getName()
        + "："
        + configBeanProperties.getWant()
        + "："
        + configBeanProperties.getUsername()
        + "："
        + configBeanProperties.getPassword();
  }
}
